REM Start qemu on windows.
@ECHO OFF

REM SDL_VIDEODRIVER=directx is faster than windib. But keyboard cannot work well.
SET SDL_VIDEODRIVER=windib

REM SDL_AUDIODRIVER=waveout or dsound can be used. Only if QEMU_AUDIO_DRV=sdl.
SET SDL_AUDIODRIVER=dsound

REM QEMU_AUDIO_DRV=dsound or fmod or sdl or none can be used. See qemu -audio-help.
SET QEMU_AUDIO_DRV=dsound
SET QEMU_AUDIO_DRV=none

REM QEMU_AUDIO_LOG_TO_MONITOR=1 displays log messages in QEMU monitor.
SET QEMU_AUDIO_LOG_TO_MONITOR=0

REM PCI-based PC(default): -M pc 
REM ISA-based PC         : -M isapc
REM -M isapc is added for NE2000 ISA card.

cd win

SET KERNEL=-kernel ..\bzImage-i386
SET INITRD=-initrd ..\rootfs-i386.cpio.gz
SET GRAPHIC=-nographic -serial null -monitor file:qemu_outfile 
SET GRAPHIC=
SET TFTP=-tftp ..
SET REDIR=-redir tcp:5023::23

rem qemu.exe -L . -m 340 -kernel bzImage -initrd rootfs.cpio.gz -localtime -M isapc -net nic -net user -tftp .
qemu.exe -L . -m 340  %KERNEL% %INITRD% -localtime -M isapc -net nic -net user %TFTP% %REDIR% %GRAPHIC%

cd ..
